A faithful encoding of programmable strategies into term rewriting systems
نویسندگان
چکیده
Rewriting is a formalism widely used in computer science and mathematical logic. When using rewriting as a programming or modeling paradigm, the rewrite rules describe the transformations one wants to operate and declarative rewriting strategies are used to control their application. The operational semantics of these strategies are generally accepted and approaches for analyzing the termination of specific strategies have been studied. We propose in this paper a generic encoding of classic control and traversal strategies used in rewrite based languages such as Maude, Stratego and Tom into a plain term rewriting system. The encoding is proven sound and complete and, as a direct consequence, established termination methods used for term rewriting systems can be applied to analyze the termination of strategy controlled term rewriting systems. The corresponding implementation in Tom generates term rewriting systems compatible with the syntax of termination tools such as AProVE and TTT2, tools which turned out to be very effective in (dis)proving the termination of the generated term rewriting systems. The approach can also be seen as a generic strategy compiler which can be integrated into languages providing pattern matching primitives; this has been experimented for Tom and performances comparable to the native Tom strategies have been observed. 1998 ACM Subject Classification F.4 Mathematical Logic and Formal Languages
منابع مشابه
Faithful (meta-)encodings of programmable strategies into term rewriting systems
Rewriting is a formalism widely used in computer science and mathematical logic. When using rewriting as a programming or modeling paradigm, the rewrite rules describe the transformations one wants to operate and rewriting strategies are used to control their application. The operational semantics of these strategies are generally accepted and approaches for analyzing the termination of specifi...
متن کاملA Logic for Rewriting Strategies
As term-rewriting has matured, with applications in areas such as automatic program transformation, the necessity of programmed control for applying rules has become apparent. Early term-rewriting systems used a xed strategy, such as innermost-leftmost matching, choosing among possibly overlapping rules nondeterministically. This mode of control is su cient for a con uent, terminating system of...
متن کاملA survey of strategies in rule-based program transformation systems
Program transformation is the mechanical manipulation of a program in order to improve it relative to some cost function and is understood broadly as the domain of computation where programs are the data. The natural basic building blocks of the domain of program transformation are transformation rules expressing a ‘one-step’ transformation on a fragment of a program. The ultimate perspective o...
متن کاملHardware Synthesis from Term Rewriting Systems
Term Rewriting System (TRS) is a good formalism for describing concurrent systems that embody asynchronous and nondeterministic behavior in their specifications. Elsewhere, we have used TRS’s to describe speculative micro-architectures and complex cache-coherence protocols, and proven the correctness of these systems. In this paper, we describe the compilation of TRS’s into a subset of Verilog ...
متن کاملMultiport Interaction Nets and Concurrency
We consider an extension of Lafont’s Interaction Nets, called Multiport Interaction Nets, and show that they are a model of concurrent computation by encoding the full π-calculus in them. We thus obtain a faithful graphical representation of the π-calculus in which every reduction step is decomposed in fully local graph-rewriting rules.
متن کاملذخیره در منابع من
با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید
عنوان ژورنال:
دوره شماره
صفحات -
تاریخ انتشار 2015